
<?php echo $html->script(array('jquery')); ?>

<div class="content-box">
<div class="box-body">
<div class="box-header clear">
<ul class="tabs clear">
	<li><?php echo $html->link('Thêm', array('controller'=>'Positions', 'action'=>'add'))?>
	</li>
</ul>
<h2>Quản lý danh sách chức vụ</h2>
</div>
<div class="box-wrap clear"><!-- TABLE -->
<div id="table"><?php echo $form->create('Position')?>
<table class="style1">
	<thead>
		<tr>
			<th><input type="checkbox" class="checkbox select-all" /></th>
			<th>Mã số</th>
			<th>Chức vụ</th>
			<th>Chức năng</th>
		</tr>
	</thead>

	<tbody>
	<?php foreach($positions as $position){?>
	<tr>
	<td><?php echo $form->checkbox('SelectedPos'.$position['Position']['id'], array('value' => $position['Position']['id']));?></td>
	<td><?php echo $position['Position']['id']?></td>
	<td><?php echo $position['Position']['position']?></td>
	<td>
		<?php echo $html->image("admin/ico_edit_16.png", array(
						"alt" => "Sửa",
						'url' => array('controller' => 'Positions', 'action' => 'edit', $position['Position']['id'])
						)); ?>
		<?php echo $html->image("admin/ico_delete_16.png", array(
						"alt" => "Xóa",
						'url' => array('controller' => 'Positions', 'action' => 'delete', $position['Position']['id']),
						'onclick'=>'return confirm(\'Bạn có chắc chắn muốn xóa?\')'
						)); ?>
		<?php
						echo $html->image( 'admin/ico_manage-users_48.png',
						array('alt'=>'Xem thông tin đoàn viên', 'url' => array('controller'=>'Positions',
													'action'=>'view', $position['Position']['id']),
													'width'=>'15px', 'height'=>'15px')); 
					?>
	</td>
	</tr>
	<?php }?>
	</tbody>
</table>
	<?php echo $form->end()?></div>
</div>
</div>
</div>
